<template>
  <el-container style="height: 100%;width: 100%; border: 1px solid #eee">
    <el-header style="width: 100%;">
      <HeaderNavigation style="width: 100%;"></HeaderNavigation>
    </el-header>
    <el-container>
      <el-aside width="200px" style="background-color: rgb(238, 241, 246)">
        <SideNavigation style="width: 100%;height: 100%"></SideNavigation>
      </el-aside>
      <el-main>
        <router-view></router-view>
      </el-main>
    </el-container>
  </el-container>
</template>
<style>
.el-header {
  background-color: #B3C0D1;
  color: #333;
  line-height: 60px;
}

.el-aside {
  color: #333;
}
</style>

<script>
import HeaderNavigation from './components/headerNavigation.vue'
import SideNavigation from './components/sideNavigation.vue'
export default {
  data () {
  },
  components: {
    HeaderNavigation,
    SideNavigation
  },
  created () {
    if (localStorage.getItem('user').account.charCodeAt(0) !== 'd') {
      this.$router.push('/login')
    }
  }
}
</script>
